﻿using System;
using System.Collections.Generic;
using System.Text;

namespace TSVNAddin.SVN
{
	public class RepositoryPathBuilder
	{
		public virtual string BuildPath(string filePath, Uri repositoryUri, Uri fileUri)
		{
			string fileRelativeUri = fileUri.ToString().Replace(repositoryUri.ToString(), string.Empty);
			
			string fileRelativePath = fileRelativeUri.Replace('/', '\\');
			
			string repositoryPath = filePath.ToLower().Replace(fileRelativePath.ToLower(), string.Empty);

			return repositoryPath;
		}
	}
}
